<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.thymeleaf.org">
<head>
    <meta charset="UTF-8">
    <title>follow</title>
    <link href="http://cdn.static.runoob.com/libs/bootstrap/3.3.7/css/bootstrap.min.css" rel="stylesheet"
          type="text/css">
</head>
<style>
    .sm-btn:hover {
        text-decoration: none;
        cursor: pointer;
    }
</style>
<body>
<!--单个用户的关注与取关-->
<div class="panel panel-default" th:fragment="follow">
    <div class="panel-heading">
        <div class="two">作者信息：</div>
        <div align="right" th:if="${!itsMe}">
            <a class="btn-sm sm-btn" id="follow" th:if="${!itsMe}"
               th:text="${isFollow==false?'关注':'已关注'}"
               th:classappend="${isFollow==false?'btn-success':'btn-default'}"
               th:onclick="'follow('+${userId}+','+${session.user==null}+')'">关注</a>
        </div>
        <div align="right" th:if="${itsMe}">
            <a class="btn-sm btn-default sm-btn">我自己</a>
        </div>
    </div>
</div>
<!--关注列表中的关注与取关-->
<div th:fragment="listFollow">
    <a class="btn-sm sm-btn btn-default" id="follow"
       th:onclick="'listFollow('+${follow.userId}+')'">关注</a>
</div>
</body>
</html>